package com.ruoyi.system.task;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.ruoyi.common.core.domain.entity.SysProject;
import com.ruoyi.system.domain.SysMaintain;
import com.ruoyi.system.service.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * 设备维护信息定时任务处理
 * 定时统计新增各项目是否有待处理维护任务
 */
@Component
@EnableScheduling
public class MaterialSyncTask {
    @Autowired
    private MaterialSyncService materialSyncService;


    //    @Scheduled(cron = "1/1 * * * * ?")

    @Scheduled(cron = "0 5 9-18 * * ?")
    public void execute() {
        materialSyncService.syncByProject();
    }

}
